package com.itheima.service.impl;

import com.itheima.dao.BookDao;
import com.itheima.service.BookService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.stereotype.Service;

/**
 * @author: dh
 * @date: 2023-10-30 20:26
 */
@Service
public class BookServiceImpl implements BookService {

    // 1.声明以下属性
    @Autowired
    @Qualifier("bookDao1")
    private BookDao bookDao;

//    public void setBookDao(BookDao bookDao) {
//
//        this.bookDao = bookDao;
//    }

    @Override
    public void save() {

        System.out.println("book service save ...");
        bookDao.save();
    }
}
